package com.sciology.xpathutility.contentassist;

import java.util.Comparator;

public class XPathCompletionProposalComparator implements Comparator {

  public XPathCompletionProposalComparator() {
  }

  public int compare(Object arg0, Object arg1) {
    XPathCompletionProposal prop1 = null;
    XPathCompletionProposal prop2 = null;
    try {
      prop1 = (XPathCompletionProposal)arg0;
      prop2 = (XPathCompletionProposal)arg1;
    } catch (ClassCastException cce) {
      return 0;
    }
    return prop1.compareTo(prop2);
  }
}
